import 'dart:io';
import 'dart:convert';
import 'package:device_info/device_info.dart';

void getDeviceInfo() async{
  DeviceInfoPlugin deviceInfo = new DeviceInfoPlugin();
  if(Platform.isIOS){
    IosDeviceInfo iosDeviceInfo = await deviceInfo.iosInfo;
    print('ios信息：${iosDeviceInfo}');
  }else if(Platform.isAndroid){
    AndroidDeviceInfo androidDeviceInfo = await deviceInfo.androidInfo;
    print('android信息：${androidDeviceInfo.type}');
  }
}

